package com.lyd.management.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;

import java.util.Objects;

public class Food {
    @TableId(type= IdType.ASSIGN_UUID)
    private String foodId;
    private String foodName;
    private String foodType;
    private Float foodPrice;
    private String foodImg;

    @Override
    public String toString() {
        return "Food{" +
                "foodId='" + foodId + '\'' +
                ", foodName='" + foodName + '\'' +
                ", foodType='" + foodType + '\'' +
                ", foodPrice=" + foodPrice +
                ", foodImg='" + foodImg + '\'' +
                '}';
    }

    public Food() {
    }

    public Food(String foodId, String foodName, String foodType, Float foodPrice, String foodImg) {
        this.foodId = foodId;
        this.foodName = foodName;
        this.foodType = foodType;
        this.foodPrice = foodPrice;
        this.foodImg = foodImg;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Food food = (Food) o;
        return Objects.equals(foodId, food.foodId) && Objects.equals(foodName, food.foodName) && Objects.equals(foodType, food.foodType) && Objects.equals(foodPrice, food.foodPrice) && Objects.equals(foodImg, food.foodImg);
    }

    @Override
    public int hashCode() {
        return Objects.hash(foodId, foodName, foodType, foodPrice, foodImg);
    }

    public String getFoodId() {
        return foodId;
    }

    public void setFoodId(String foodId) {
        this.foodId = foodId;
    }

    public String getFoodName() {
        return foodName;
    }

    public void setFoodName(String foodName) {
        this.foodName = foodName;
    }

    public String getFoodType() {
        return foodType;
    }

    public void setFoodType(String foodType) {
        this.foodType = foodType;
    }

    public Float getFoodPrice() {
        return foodPrice;
    }

    public void setFoodPrice(Float foodPrice) {
        this.foodPrice = foodPrice;
    }

    public String getFoodImg() {
        return foodImg;
    }

    public void setFoodImg(String foodImg) {
        this.foodImg = foodImg;
    }
}
